package com.hiyee.goods.mapper;

import com.hiyee.api.mapper.MyMapper;
import com.hiyee.pojo.Goods;
import com.hiyee.pojo.repo.GoodsInfoRepo;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

@Repository
public interface GoodsMapper extends MyMapper<Goods> {
    /**
     * 根据 id 获取商品信息（列表）
     * @param Long id
     * @return Goods
     */
    public Goods getById(@Param("goods_id") Long id);

    /**
     * 根据 id 获取商品信息（详情）
     * @param Long id
     * @return Goods
     */
    public GoodsInfoRepo getInfoById(@Param("goods_id") Long id);
}